<?php

namespace App;

use Illuminate\Database\Eloquent\Model;
use App\Category;
use Illuminate\Database\Eloquent\SoftDeletes;
class Data extends Model
{
    protected $guarded=[];

    use SoftDeletes;
    public function getCategoryAttribute(){
        return Category::select('category_name')->find($this->category_id);
    }
}
